using System;
using System.ComponentModel;
using System.ComponentModel.Design;
using System.Collections;
using System.Drawing;
using System.Workflow.ComponentModel.Compiler;
using System.Workflow.ComponentModel.Serialization;
using System.Workflow.ComponentModel;
using System.Workflow.ComponentModel.Design;
using System.Workflow.Runtime;
using System.Workflow.Activities;
using System.Workflow.Activities.Rules;

namespace Contoso.Workflow.Activity
{
    [ToolboxItem(typeof(CompositeStateToolboxItem))]
    public partial class RequestActivity : System.Workflow.Activities.StateActivity
	{
		public RequestActivity()
		{
			InitializeComponent();
		}
	}


    public class CompositeStateToolboxItem : ActivityToolboxItem
    {

        protected override IComponent[] CreateComponentsCore(IDesignerHost host)
        {
            RequestActivity compositeState = new RequestActivity();

            compositeState.Activities.Add(new StateInitializationActivity());

          //  EventDrivenActivity 

            compositeState.Activities.Add(new EventDrivenActivity());

            compositeState.Activities.Add(new StateFinalizationActivity());

            return new IComponent[] { compositeState };

        }

    }


}
